﻿@{
    ViewBag.Title = "Index";
    Layout = "~/Views/Shared/_Layout.cshtml";
}

<h1>Character import</h1>


<section class="content">

    <div class="block">
        <p class="first">You can import an existing character from an HQML file.</p>

        <p>Generate the HQML file from the Excel spreadsheet and save it to a local folder.
        Click the browse button below and select the HQML (or HQMLM) file you saved above.</p>

        <p>Click the import button to begin the import process.</p>

        <p class="last">If you already have a character on the scratch pad with the same name it will be overwritten.</p>
    </div>

@using (Html.BeginForm("Index", "CharacterImport", FormMethod.Post, new { enctype = "multipart/form-data" }))
{
    <fieldset class="block form">
        <legend>Character import</legend>

        <div class="field-item">
            <div class="label"><label for="fileUpload">HQML file:</label></div>
            <input type="file" name="fileUpload" />
            @Html.ValidationMessage("fileUpload", new { @class = "error"})
        </div>

        <p>
            <input type="submit" value="Import" />
        </p>
    </fieldset>
}
</section>